Skip to content

Drop symbol literals #5681

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jan 10, 2019
Merged

Drop symbol literals #5681

merged 5 commits into from
Jan 10, 2019

Conversation

odersky
Copy link
Contributor

@odersky odersky commented Jan 6, 2019

Symbol literals are

  • disallowed in normal mode
  • allowed with a warning in Scala-2 mode
  • they can be rewritten to Symbol(...) calls under -migration -rewrite

Open patch file for writing later only once all patches are applied,
so that any assertion errors during patch generation cannot result
in an empty output file.
The syntax highlighter creates its own copy of a parser. This parser
should not apply any patches, since these would be duplicates.
Offer to rewrite them to Symbol("...") calls.
All tests were automatically rewritten
@odersky odersky changed the title Drop symlits Drop symbol literals Jan 6, 2019
@odersky odersky requested a review from liufengyun January 7, 2019 10:04
Copy link
Contributor

@liufengyun liufengyun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@liufengyun liufengyun merged commit 29a6179 into scala:master Jan 10, 2019
@liufengyun liufengyun deleted the drop-symlits branch January 10, 2019 14:16
liufengyun added a commit to dotty-staging/sourcecode that referenced this pull request Jan 23, 2019
Symbol literals are dropped: scala/scala3#5681
bishabosha pushed a commit to dotty-staging/sourcecode that referenced this pull request Aug 21, 2019
Symbol literals are dropped: scala/scala3#5681
anatoliykmetyuk pushed a commit to dotty-staging/sourcecode that referenced this pull request Nov 11, 2019
Symbol literals are dropped: scala/scala3#5681
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants